package bean;

public class addBean {
    private int n;
    private int sum;

    public addBean() {
        n = 0;
        sum=0;
    }

    public int getN() {
        return n;
    }

    public void setN(int n) {
        this.n = n;
    }

    public int getAdder() {
        for (int i=0;i<=n;i++){
            sum=sum+i;
        }
        return sum;
    }
}
